package com.itheima.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.itheima.entity.PageResult;
import com.itheima.entity.QueryPageBean;
import com.itheima.service.OrderManagementService;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/orderManagement")
public class OrderManagementController {
    @Reference//查找服务
    private OrderManagementService orderManagementService;

    @RequestMapping("/findPage")
    public PageResult add(@RequestBody QueryPageBean queryPageBean){
        PageResult pageResult = orderManagementService.findPage(queryPageBean);
        return pageResult;
    }
}
